﻿namespace NetFx.SMIL.AST
{
  using System;
  using System.Text;
  using System.Collections;
  using System.Collections.Generic;

  using NetFx.SMIL.Definitions;
  using NetFx.SMIL.References;

  #region AST 108
  /// <summary>
  /// 获取地址(&操作)。
  /// </summary>
  public interface IAddressReferenceExpression : IExpression
  {
    /// <summary>
    /// 需获取地址的表达式。
    /// </summary>
    IExpression Expression { get; set; }
  }  
  /// <summary>
  /// 获取地址对象(*操作)。
  /// </summary>
  public interface IAddressDereferenceExpression : IExpression
  {
    /// <summary>
    /// 需还愿内容的表达式。
    /// </summary>
    IExpression Expression { get; set; }
  }
  /// <summary>
  /// 获取地址(&/AddressOf操作)。
  /// </summary>
  public interface IAddressOfExpression : IExpression
  {
    /// <summary>
    /// 需获取地址的表达式。
    /// </summary>
    IExpression Expression { get; set; }
  }

  /// <summary>
  /// 
  /// </summary>
  public interface IAddressOutExpression : IExpression
  {
    IExpression Expression { get; set; }
  }

  public interface IArgumentListExpression : IExpression
  {

  }

  public interface IArgumentReferenceExpression : IExpression
  {
    IParameterReference Parameter { get; set; }
  }

  public interface IArrayCreateExpression : IExpression
  {
    IType Type { get; set; }
    IExpressionCollection Initializers { get; }
    IExpressionCollection Sizes { get; }
  }
  public interface IArrayDimension
  {
    int LowerBound { get; }
    int UpperBound { get; }
  }
  public interface IArrayIndexerExpression : IExpression
  {
    IExpressionCollection Indices { get; }
    IExpression Target { get; set; }
  }
  public interface IArrayType : IType, IComparable
  {
    IArrayDimensionCollection Dimensions { get; }
    IType ElementType { get; set; }
  }
  public interface IAssignStatement : IStatement
  {
    IExpression Expression { get; set; }
    IExpression Target { get; set; }
  }
  public interface IAttachEventStatement : IStatement
  {
    IEventReferenceExpression Event { get; set; }
    IExpression Listener { get; set; }
  }
  public interface IBaseReferenceExpression : IExpression
  {
  }
  public interface IBinaryExpression : IExpression
  {
    BinaryOperator Operator { get; set; }
    IExpression Left { get; set; }
    IExpression Right { get; set; }
  }
  public interface IBlockStatement : IStatement
  {
    IStatementCollection Statements { get; }
  }
  public interface IBreakStatement : IStatement
  {
  }
  public interface ICanCastExpression : IExpression
  {
    IExpression Expression { get; set; }
    IType TargetType { get; set; }
  }
  public interface ICastExpression : IExpression
  {
    IExpression Expression { get; set; }
    IType TargetType { get; set; }
  }
  public interface ICatchClause
  {
    IBlockStatement Body { get; set; }
    IExpression Condition { get; set; }
    IVariableDeclaration Variable { get; set; }
  }
  public interface IComment
  {
    string Text { get; }
  }
  public interface ICommentStatement : IStatement
  {
    IComment Comment { get; }
  }
  public interface IConditionExpression : IExpression
  {
    IExpression Condition { get; set; }
    IExpression Then { get; set; }
    IExpression Else { get; set; }
  }
  public interface IConditionStatement : IStatement
  {
    IExpression Condition { get; set; }
    IBlockStatement Then { get; set; }
    IBlockStatement Else { get; set; }
  }
  public interface IConstructorDeclaration : IMethodDeclaration, IMethodReference, IMethodSignature, IMemberDeclaration, IMemberReference, ICustomAttributeProvider, IGenericArgumentProvider, IComparable
  {
    IExpressionCollection BaseArguments { get; }
    IExpressionCollection ChainedArguments { get; }
  }
  public interface IContinueStatement : IStatement
  {
  }
  public interface ICustomAttribute
  {
    IExpressionCollection Arguments { get; }
    IMethodReference Constructor { get; set; }
  }
  public interface ICustomAttributeProvider
  {
    ICustomAttributeCollection Attributes { get; }
  }
  public interface IDelegateCreateExpression : IExpression
  {
    ITypeReference DelegateType { get; set; }
    IMethodReference Method { get; set; }
    IExpression Target { get; set; }
  }
  public interface IDelegateInvokeExpression : IExpression
  {
    IExpressionCollection Arguments { get; }
    IExpression Target { get; set; }
  }
  public interface IDoStatement : IStatement
  {
    IBlockStatement Body { get; set; }
    IExpression Condition { get; set; }
  }
  public interface IEventDeclaration : IMemberDeclaration, ICustomAttributeProvider, IEventReference, IMemberReference, IComparable
  {
    IMethodReference AddMethod { get; set; }
    IMethodReference InvokeMethod { get; set; }
    bool IsRuntimeSpecialName { get; set; }
    bool IsSpecialName { get; set; }
    IMethodReference RemoveMethod { get; set; }
  }
  public interface IEventReference : IMemberReference, IComparable
  {
    ITypeReference EventType { get; set; }
    IEventDeclaration Resolve();
  }
  public interface IEventReferenceExpression : IExpression
  {
    IEventReference Event { get; set; }
    IExpression Target { get; set; }
  }
  public interface IExceptionHandler
  {
    ITypeReference CatchType { get; }
    int FilterOffset { get; }
    int HandlerLength { get; }
    int HandlerOffset { get; }
    int TryLength { get; }
    int TryOffset { get; }
    ExceptionHandlerType Type { get; }
  }
  public interface IExpression
  {
  }
  public interface IExpressionStatement : IStatement
  {
    IExpression Expression { get; set; }
  }
  public interface IFieldDeclaration : IFieldReference, IMemberDeclaration, IMemberReference, IComparable, ICustomAttributeProvider
  {
    IExpression Initializer { get; set; }
    bool IsLiteral { get; set; }
    bool IsReadOnly { get; set; }
    bool IsRuntimeSpecialName { get; set; }
    bool IsSpecialName { get; set; }
    bool IsStatic { get; set; }
    FieldVisibility Visibility { get; set; }
  }
  public interface IFieldReference : IMemberReference, IComparable
  {
    IType FieldType { get; set; }
    IFieldDeclaration Resolve();
  }
  public interface IFieldReferenceExpression : IExpression
  {
    IFieldReference Field { get; set; }
    IExpression Target { get; set; }
  }
  public interface IFixedStatement : IStatement
  {
    IBlockStatement Body { get; set; }
    IExpression Expression { get; set; }
    IVariableDeclaration Variable { get; set; }
  }
  public interface IForEachStatement : IStatement
  {
    IBlockStatement Body { get; set; }
    IExpression Expression { get; set; }
    IVariableDeclaration Variable { get; set; }
  }
  public interface IForStatement : IStatement
  {
    IBlockStatement Body { get; set; }
    IExpression Condition { get; set; }
    IStatement Increment { get; set; }
    IStatement Initializer { get; set; }
  }
  public interface IFunctionPointer : IType, IComparable, IMethodSignature
  {
  }
  public interface IGenericArgument : IType, IComparable
  {
    IGenericArgumentProvider Owner { get; set; }
    int Position { get; set; }
    IType Resolve();
  }
  public interface IGenericArgumentProvider : IComparable
  {
    ITypeCollection GenericArguments { get; }
  }
  public interface IGenericDefaultExpression : IExpression
  {
    IGenericArgument GenericArgument { get; set; }
  }
  public interface IGenericParameter : IType, IComparable, ICustomAttributeProvider
  {
    ITypeCollection Constraints { get; }
    string Name { get; set; }
    IGenericArgumentProvider Owner { get; set; }
    GenericParameterVariance Variance { get; set; }
  }
  public interface IGotoStatement : IStatement
  {
    string Name { get; set; }
    IBlockStatement Owner { get; set; }
    ILabeledStatement Resolve();
  }
  public interface ILabeledStatement : IStatement
  {
    string Name { get; set; }
    IStatement Statement { get; set; }
  }
  public interface ILiteralExpression : IExpression
  {
    object Value { get; set; }
  }
  public interface ILockStatement : IStatement
  {
    IBlockStatement Body { get; set; }
    IExpression Expression { get; set; }
  }
  public interface IMemberDeclaration : IMemberReference, IComparable, ICustomAttributeProvider
  {
  }
  public interface IMemberReference : IComparable
  {
    IType DeclaringType { get; set; }
    string Name { get; set; }
  }
  public interface IMemoryCopyStatement : IStatement
  {
    IExpression Destination { get; set; }
    IExpression Length { get; set; }
    IExpression Source { get; set; }
  }
  public interface IMemoryInitializeStatement : IStatement
  {
    IExpression Length { get; set; }
    IExpression Offset { get; set; }
    IExpression Value { get; set; }
  }
  public interface IMethodBody
  {
    int CodeSize { get; }
    IExceptionHandlerCollection ExceptionHandlers { get; }
    IInstructionCollection Instructions { get; }
    ITypeCollection LocalVariables { get; }
    int MaxStack { get; }
    int Token { get; }
  }
  public interface IMethodDeclaration : IMethodReference, IMethodSignature, IMemberDeclaration, IMemberReference, ICustomAttributeProvider, IGenericArgumentProvider, IComparable
  {

    IBlockStatement Body { get; set; }
    bool IsAbstract { get; set; }
    bool IsFinal { get; set; }
    bool IsHideBySignature { get; set; }
    bool IsNewSlot { get; set; }
    bool IsRuntimeSpecialName { get; set; }
    bool IsSpecialName { get; set; }
    bool IsStatic { get; set; }
    bool IsVirtual { get; set; }
    MethodVisibility Visibility { get; set; }
    IMethodInstanceDeclaration BindGenericParameters(ITypeCollection types);
  }
  public interface IMethodInstanceDeclaration : IMethodDeclaration, IMemberDeclaration, ICustomAttributeProvider, IMethodInstanceReference, IMethodReference, IMemberReference, IMethodSignature, IGenericArgumentProvider, IComparable
  {
  }
  public interface IMethodInstanceReference : IMethodReference, IMemberReference, IMethodSignature, IGenericArgumentProvider, IComparable
  {
    IMethodReference GenericMethod { get; set; }
  }
  public interface IMethodInvokeExpression : IExpression
  {
    IExpressionCollection Arguments { get; }
    IExpression Method { get; set; }
  }
  public interface IMethodReference : IMemberReference, IMethodSignature, IGenericArgumentProvider, IComparable
  {
    IMethodDeclaration Resolve();
  }
  public interface IMethodReferenceExpression : IExpression
  {
    IMethodReference Method { get; set; }
    IExpression Target { get; set; }
  }
  public interface IMethodReturnStatement : IStatement
  {
    IExpression Expression { get; set; }
  }
  public interface IMethodReturnType : ICustomAttributeProvider
  {
    IType Type { get; set; }
  }
  public interface IMethodSignature
  {
    MethodCallingConvention CallingConvention { get; set; }
    bool ExplicitThis { get; set; }
    bool HasThis { get; set; }
    IParameterDeclarationCollection Parameters { get; }
    IMethodReturnType ReturnType { get; set; }
  }
  public interface IModule : IModuleName, IComparable, ICustomAttributeProvider
  {
    IAssembly Assembly { get; set; }
    IAssemblyNameCollection AssemblyReferences { get; }
    string Location { get; set; }
    IModuleNameCollection ModuleReferences { get; }
    ITypeDeclarationCollection Types { get; }
    IUnmanagedResourceCollection UnmanagedResources { get; }
    Guid Version { get; set; }
  }
  public interface IModuleName : IComparable
  {
    IModule Resolve();

    string Name { get; }
  }
  public interface INamedArgumentExpression : IExpression
  {
    IMemberReference Member { get; set; }
    IExpression Value { get; set; }
  }
  public interface INamespace : IPropertyChange
  {
    string Name { get; set; }
    ITypeDeclarationCollection Types { get; }
  }
  public interface IObjectCreateExpression : IExpression
  {
    IExpressionCollection Arguments { get; }
    IMethodReference Constructor { get; set; }
  }
  public interface IObjectInitializeStatement : IStatement
  {
    IExpression Target { get; set; }
    IType Type { get; set; }
  }
  public interface IOptionalModifier : IType, IComparable
  {
    IType ElementType { get; }
    ITypeReference Modifier { get; }
  }
  public interface IParameterDeclaration : IParameterReference, ICustomAttributeProvider
  {
    IExpression DefaultValue { get; set; }
    IType ParameterType { get; set; }
  }
  public interface IParameterReference
  {
    string Name { get; set; }
    IParameterDeclaration Resolve();
  }
  public interface IPinnedType : IType, IComparable
  {
    IType ElementType { get; }
  }
  public interface IPointerType : IType, IComparable
  {
    IType ElementType { get; set; }
  }
  public interface IPropertyChange
  {
    event PropertyChangedEventHandler PropertyChanged;
  }
  public interface IPropertyDeclaration : IMemberDeclaration, ICustomAttributeProvider, IPropertyReference, IMemberReference, IComparable
  {
    IMethodReference GetMethod { get; set; }
    IExpression Initializer { get; set; }
    bool IsRuntimeSpecialName { get; set; }
    bool IsSpecialName { get; set; }
    IMethodReference SetMethod { get; set; }
  }
  public interface IPropertyIndexerExpression : IExpression
  {
    IExpressionCollection Indices { get; }
    IPropertyReferenceExpression Target { get; set; }
  }
  public interface IPropertyReference : IMemberReference, IComparable
  {
    IParameterDeclarationCollection Parameters { get; }
    IType PropertyType { get; set; }
    IPropertyDeclaration Resolve();
  }
  public interface IPropertyReferenceExpression : IExpression
  {
    IPropertyReference Property { get; set; }
    IExpression Target { get; set; }
  }
  public interface IReferenceType : IType, IComparable
  {
    IType ElementType { get; set; }
  }
  public interface IRemoveEventStatement : IStatement
  {
    IEventReferenceExpression Event { get; set; }
    IExpression Listener { get; set; }
  }
  public interface IRequiredModifier : IType, IComparable
  {
    IType ElementType { get; }
    ITypeReference Modifier { get; }
  }
  public interface ISizeOfExpression : IExpression
  {
    IType Type { get; set; }
  }
  public interface IStackAllocateExpression : IExpression
  {
    IExpression Expression { get; set; }
    IType Type { get; set; }
  }
  public interface IStatement
  {
  }
  public interface IStatementExpression : IExpression
  {
    IStatement Statement { get; set; }
  }
  public interface ISwitchCase
  {
    IExpressionCollection Conditions { get; }
    IBlockStatement Body { get; set; }
  }
  public interface ISwitchStatement : IStatement
  {
    ISwitchCaseCollection Cases { get; }
    IExpression Expression { get; set; }
  }
  public interface IThisReferenceExpression : IExpression
  {
  }
  public interface IThrowExceptionStatement : IStatement
  {
    IExpression Expression { get; set; }
  }
  public interface ITryCastExpression : IExpression
  {
    IExpression Expression { get; set; }
    IType TargetType { get; set; }
  }
  public interface ITryCatchFinallyStatement : IStatement
  {
    ICatchClauseCollection CatchClauses { get; }
    IBlockStatement Fault { get; set; }
    IBlockStatement Finally { get; set; }
    IBlockStatement Try { get; set; }
  }
  public interface IType : IComparable
  {
  }
  public interface ITypeDeclaration : ITypeReference, IType, ICustomAttributeProvider, IGenericArgumentProvider, IComparable
  {
    ITypeReference BaseType { get; set; }
    IEventDeclarationCollection Events { get; }
    IFieldDeclarationCollection Fields { get; }
    ITypeReferenceCollection Interfaces { get; }
    bool IsAbstract { get; set; }
    bool IsBeforeFieldInit { get; set; }
    bool IsInterface { get; set; }
    bool IsRuntimeSpecialName { get; set; }
    bool IsSealed { get; set; }
    bool IsSpecialName { get; set; }
    IMethodDeclarationCollection Methods { get; }
    ITypeDeclarationCollection NestedTypes { get; }
    IPropertyDeclarationCollection Properties { get; }
    TypeVisibility Visibility { get; set; }
    ITypeInstanceDeclaration BindGenericParameters(ITypeCollection types);
  }
  public interface ITypeInstanceDeclaration : ITypeDeclaration, ICustomAttributeProvider, ITypeInstanceReference, ITypeReference, IType, IGenericArgumentProvider, IComparable
  {
  }
  public interface ITypeInstanceReference : ITypeReference, IType, IGenericArgumentProvider, IComparable
  {
    ITypeReference GenericType { get; set; }
  }
  public interface ITypeOfExpression : IExpression
  {
    IType Type { get; set; }
  }
  public interface ITypeOfTypedReferenceExpression : IExpression
  {
    IExpression Expression { get; set; }
  }
  public interface ITypeReference : IType, IGenericArgumentProvider, IComparable
  {
    string Name { get; set; }
    string Namespace { get; set; }
    object Owner { get; set; }

    ITypeDeclaration Resolve();
  }
  public interface ITypeReferenceExpression : IExpression
  {
    ITypeReference Type { get; set; }
  }
  public interface IUnaryExpression : IExpression
  {
    UnaryOperator Operator { get; set; }
    IExpression Expression { get; set; }
  }
  public interface IUsingStatement : IStatement
  {
    IVariableDeclaration Variable { get; set; }
    IExpression Expression { get; set; }
    IBlockStatement Body { get; set; }
  }
  public interface IVariableDeclaration : IVariableReference
  {
    IType VariableType { get; set; }
  }
  public interface IVariableDeclarationExpression : IExpression
  {
    IVariableDeclaration Variable { get; set; }
  }
  public interface IVariableReference
  {
    string Name { get; set; }
    IBlockStatement Owner { get; set; }
    
    IVariableDeclaration Resolve();

  }
  public interface IVariableReferenceExpression : IExpression
  {
    IVariableReference Variable { get; set; }
  }
  public interface IWhileStatement : IStatement
  {
    IExpression Condition { get; set; }
    IBlockStatement Body { get; set; }
  }
  #endregion



}
